import axios from '@/utils/request.js'

function filter(data) {
    return axios({
        url: '/api/forumAnswer/admin/filter',
        method: 'POST',
        data
    })
}


function all() {
    return axios({
        url: '/api/forumAnswer/admin/all',
        method: 'POST'
    })
}

function del(id) {
    return axios({
        url: '/api/forumAnswer/del/' + id,
        method: 'POST',
    })
}

function add(data) {
    return axios({
        url: '/api/forumAnswer/answer',
        method: 'POST',
        data
    })
}

function edit(data) {
    return axios({
        url: '/api/forumAnswer/edit',
        method: 'POST',
        data
    })
}

export {all, del, add, edit, filter}